package vip.ola.task.reconciliation.scheduled;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import vip.ola.core.common.util.MyLog;
import vip.ola.task.common.service.RpcCommonService;

@Component
public class TodayAmountScheduled {

    private static final MyLog _log = MyLog.getLog(TodayAmountScheduled.class);

    @Autowired
    private RpcCommonService rpcCommonService;

    @Scheduled(cron="0 0 0 ? * *")   // 每日00:00执行一次
    public void resetAmount() {

        rpcCommonService.rpcMchAccountService.resetTodayAmount();
        rpcCommonService.rpcAgentAccountService.resetTodayAmount();

    }
}
